package com.hexb.smh.service;

import com.hexb.smh.entity.Config;
import com.hexb.smh.entity.EvaluateLevel;
import com.hexb.smh.entity.enums.ConfigType;
import com.hexb.smh.entity.param.config.ExpressionValidParam;
import com.hexb.smh.entity.view.EvaluateResult;

import javax.validation.constraints.NotNull;
import java.io.OutputStream;
import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * @author : hexb
 */
public interface IConfigService {

    int ROUND_TYPE = BigDecimal.ROUND_HALF_UP;
    int SCALE = 8;

    int saveOrUpdate(@NotNull Config config);

    int saveBatch(@NotNull List<Config> configList);

    List<Config> list();

    Map<ConfigType, Config> map();

    String validExpression(String expression, ExpressionValidParam param);

}
